package com.example.tests;

import org.junit.*;

import com.example.data.User;
import com.example.pages.LoginPage;
import static org.junit.Assert.*;



public class LoginTest extends TestBase{
	
	@Test
	public void testLoginLogout() throws Exception {
		
		User user= new User().withName("admin").withPassword("admin");
		LoginPage loginPage = goToMainPage()
			.loginWithValidCredentials(user)
			.logout();
		assertTrue("Form 'Login' is absent", loginPage.isOnThisPage());
	}

}
